public class Test0114 {
    public static void main(String[] args) {
        String s = "abcbad";
        System.out.println( huiwen(s));;
    }
        public static boolean huiwen(String s) {
            int left = 0;
            int right = s.length() - 1;
            char[] arr = s.toCharArray();
            while (left < right) {
                if (arr[left] == arr[right]) {
                   return true;
                } else {
                left++;
                right--;
            }

        }
            return false;
    }
}




